// Copyright (c) Huawei Technologies Co., Ltd. 2022-2022. All rights reserved.

// 首页查询结构体定义
package homepage

type FleetRuntimeState struct {
	TotalCount		int32			`json:"total_count"`
	Count			int32			`json:"count"`
	Fleets			[]Fleet			`json:"fleets"`
}

type Fleet struct {
	FleetId				string			`json:"fleet_id"`
	FleetName			string			`json:"fleet_name"`
	State				string			`json:"state"`
	CreationTime		string			`json:"creation_time"`
	InstanceCount		int32			`json:"instance_count"`
	AppProcessCount		int32			`json:"process_count"`
	ServerSessionCount	int32			`json:"server_session_count"`
	Instances   		[]Instance		`json:"instances"`
	AppProcesses  		[]AppProcess	`json:"app_processes"`
	ServerSessions  	[]ServerSession `json:"server_sessions"`
}

type FleetInfo struct {
	FleetId				string			`json:"fleet_id"`
	FleetName			string			`json:"fleet_name"`
	State				string			`json:"state"`
	Region				string			`json:"region"`
	CreationTime		string			`json:"creation_time"`
}

type Instance struct {
	State 		string		`json:"state"`
	Count		int32		`json:"count"`
}

type AppProcess	struct {
	State		string		`json:"state"`
	Count		int32		`json:"count"`
}

type ServerSession struct {
	State		string		`json:"state"`
	Count		int32		`json:"count"`
}

type ShowAppProcessStatesResponse struct {
	FleetID       string         `json:"fleet_id"`
	ProcessCounts []AppProcess 	 `json:"process_counts"`
}

type ShowServerSessionStatesResponse struct {
	FleetID       			string         		 `json:"fleet_id"`
	ServerSessionCounts 	[]ServerSession 	 `json:"server_session_counts"`
}